#include <stdio.h>

int main()
{
   printf("=================================================================\n");
   // 声明short类型的变量，并赋值
   short s1 = 10;
   signed short s2 = -10;
   unsigned short s3 = 20;
   // 输出有符号和无符号的s1,s2,s3变量的值
   printf("有符号的short变量:s1=%hd,s2=%hd,无符号的short变量:s3=%hu\n", s1, s2, s3);
   // short变量也都可以使用%d占位符
   printf("有符号的short变量:s1=%d,s2=%d,无符号的short变量:s3=%d\n", s1, s2, s3);

   printf("=================================================================\n");
   // 声明int类型的变量，并赋值
   int i1 = 10;
   signed int i2 = -10;
   unsigned int i3 = 20;
   // 输出有符号和无符号的i1,i2,i3变量的值
   printf("有符号的int变量:i1=%d,i2=%d,无符号的int变量:i3=%d\n", i1, i2, i3);

   printf("=================================================================\n");
   // 声明long类型的变量，并赋值
   long l1 = 10L;
   signed long l2 = -100L;
   unsigned long l3 = 1000LU;
   // 输出有符号和无符号的l1,l2,l3变量的值
   printf("有符号的long变量:l1=%ld,l2=%ld,无符号的long变量:l3=%lu\n", l1, l2, l3);
   printf("=================================================================\n");
   // 声明long long类型的变量，并赋值
   long long ll1 = 10LL;
   signed long long ll2 = -100LL;
   unsigned long long ll3 = 1000LLU;
   // 输出有符号和无符号的ll1,ll2,ll3变量的值
   printf("有符号的long long变量:ll1=%lld,ll2=%lld,无符号的long long变量:l3=%llu\n", ll1, ll2, ll3);
   return 0;
}
